<?
	$ncMenu = getParam('ncMenu', ( $this->cAction == START_ACTION )  ? START_MENU : '' );
	
	if ( $ncMenu  )
	{
		list ( $nVista, $cdMenu ) = $this->oDatabase->getArray('SELECT nVista, cdMenu FROM gtMenu As Men WHERE Men.ncMenu= ' . $ncMenu);
		$this->aDatos[$cTemplateId][nVista] = $nVista;
		$this->aDatos[$cTemplateId][cdMenu] = extractLanguage($cdMenu, $lang) ;
		
		$aPaneles = array (  1 => 'body_left' , 2 => 'body_main' ,  3=>'body_right' ); //concat(Cmp.cParametros, '&amp;', MCm.cParametros) 
		$aCeldas = $this->oDatabase->getMatrix("SELECT MCm.nPanel, nOrden, MCm.ncOrden, Cmp.ncComponente, Cmp.cdComponente, Cmp.cAccion, Cmp.cClass, Cmp.cModulo, MCm.cParametros as cParametrosCom, Cmp.cParametros as cParametros FROM gtMenuComponente AS MCm JOIN gtComponente as Cmp ON MCm.ncComponente = Cmp.ncComponente WHERE Cmp.ncEstadoPublicacion= 2 AND MCm.ncMenu= $ncMenu ORDER BY MCm.nPanel, nOrden"); 
		for ( $nIndex = 0; $nIndex < count($aCeldas) ;$nIndex++ ) 
		{
			$cParametros = $aCeldas[$nIndex][cParametros] = mergeParametros( $aCeldas[$nIndex][cParametrosCom] , $aCeldas[$nIndex][cParametros] );
			
			$cPanel = $aPaneles[$aCeldas[$nIndex][nPanel]];
			$oModule =& loadModule($aCeldas[$nIndex][cModulo]);
			$oModule->aDatos[$aCeldas[$nIndex][ncOrden]][ncOrden]  = $aCeldas[$nIndex][ncOrden];			
			$oModule->aDatos[$aCeldas[$nIndex][ncOrden]][nOrden]  = $aCeldas[$nIndex][nOrden];			
			$oModule->loadTemplatePage($aCeldas[$nIndex][cAccion], $aCeldas[$nIndex][ncOrden], $cParametros );
			$this->aDatos[$cTemplateId][$cPanel][]  = $aCeldas[$nIndex];
		}
		
		$this->aDatos[$cTemplateId][aModos] = defined('MODO_COMPONENTE') ? MODO_COMPONENTE: 1;
	}		

/*
		$aCeldas = $this->oDatabase->getMatrix("SELECT MCm.nPanel, Cmp.ncComponente, Cmp.cdComponente, Cmp.cAccion, Cmp.cClass, Cmp.cModulo, ifnull(MCm.cParametros, Cmp.cParametros) as cParametros FROM gtMenuComponente AS MCm JOIN gtComponente as Cmp ON MCm.ncComponente = Cmp.ncComponente WHERE Cmp.ncEstadoPublicacion= 2 AND MCm.ncMenu= $ncMenu ORDER BY MCm.nPanel, nOrden"); 
		foreach ( $aCeldas as $aCelda) 
		{
			$cPanel = $aPaneles[$aCelda[nPanel]];
			$oModule =& loadModule($aCelda[cModulo]);
			$oModule->loadTemplatePage($aCelda[cAccion], $aCelda[ncComponente], $aCelda[cParametros] );
			$this->aDatos[$cTemplateId][$cPanel][]  = $aCelda;
		}
		$this->aDatos[$cTemplateId][aModos] = defined('MODO_COMPONENTE') ? MODO_COMPONENTE: 1;
	}		

*/
?>